<%@ page import="edu.nuist.studentadmin.model.Student" %>
<%@ page import="java.util.List" %>
<%@ page import="edu.nuist.studentadmin.dao.impl.StudentDaoImpl" %><%--
  Created by IntelliJ IDEA.
  User: lqj
  Date: 2021/12/27
  Time: 3:52 下午
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>学生列表展示</title>
    <style>
        table{
            border: 1px solid black;
            border-collapse: collapse;
            margin:0 auto;
        }
        tr{
            border: 1px solid black;
            border-collapse: collapse;
            margin:0 auto;
        }
        td{
            border: 1px solid black;
            border-collapse: collapse;
            margin:0 auto;
        }
        img{
            width: 100px;
            height: 100px;
        }
    </style>
</head>
<body>
    <h2 align="center">信息系统与管理19级同学名单</h2>
     <table>
         <tr>
             <td>学号</td>
             <td>姓名</td>
             <td>班级</td>
             <td>性别</td>
             <td>电话</td>
             <td>系部</td>
             <td>宿舍</td>
             <td>照片</td>
         </tr>
         <%
             List<Student> students= new StudentDaoImpl().getAllStudents();
             for(Student s: students){
         %>
         <tr>
             <td><%=s.getStuNo()%></td>
             <td><%=s.getStuName()%></td>
             <td><%=s.getClasses()%></td>
             <td><%=s.getGender()%></td>
             <td><%=s.getTel()%></td>
             <td><%=s.getDepartment()%></td>
             <td><%=s.getDormno()%></td>
             <td>
                 <img src="<%=s.getPhotoPath()%>"/></td>
         </tr>
         <%}%>
     </table>
</body>
</html>
